home *** CD-ROM | disk | FTP | other *** search
/ Inside Multimedia 1994 April / Inside Multimedia CD-ROM (April 1994).iso / prg / gs / gssource.exe / VMS-GCC.MAK < prev    next >
Encoding:
Text File  |  1992-08-24  |  6.3 KB  |  260 lines

  1. $ !    Copyright (C) 1989, 1992 Aladdin Enterprises.  All rights reserved.
  2. $ !    Distributed by Free Software Foundation, Inc.
  3. $ !
  4. $ ! This file is part of Ghostscript.
  5. $ !
  6. $ ! Ghostscript is distributed in the hope that it will be useful, but
  7. $ ! WITHOUT ANY WARRANTY.  No author or distributor accepts responsibility
  8. $ ! to anyone for the consequences of using it or for whether it serves any
  9. $ ! particular purpose or works at all, unless he says so in writing.  Refer
  10. $ ! to the Ghostscript General Public License for full details.
  11. $ !
  12. $ ! Everyone is granted permission to copy, modify and redistribute
  13. $ ! Ghostscript, but only under the conditions described in the Ghostscript
  14. $ ! General Public License.  A copy of this license is supposed to have been
  15. $ ! given to you along with Ghostscript so you can know your rights and
  16. $ ! responsibilities.  It should be in a file named COPYING.  Among other
  17. $ ! things, the copyright notice and this notice must be preserved on all
  18. $ ! copies.
  19. $ !
  20. $ !
  21. $ ! "makefile" for Ghostscript, VMS / GNU C / DECwindows (X11) configuration.
  22. $ !
  23. $ !
  24. $ ! Execute this command file while in the GhostScript directory!
  25. $ !
  26. $ !
  27. $ ! To build a debugging configuration, issue the command:
  28. $ !
  29. $ !          $ @VMS-CC.MAK DEBUG
  30. $ !
  31. $ ! Do not  abbreviate "DEBUG".  To specify an alternate directory for
  32. $ ! GS_LIB_DEFAULT, issue the command:
  33. $ !
  34. $ !          $ @VMS-CC.MAK directory
  35. $ !
  36. $ ! with "directory" a fully qualified directory name.  "directory" cannot
  37. $ ! be DEBUG (otherwise it will be confused with the DEBUG switch).  Both
  38. $ ! the DEBUG switch and a directory name may be specified on the same
  39. $ ! command line and in either order.
  40. $ !
  41. $ CDEF = ""
  42. $ LDEF = ""
  43. $ !
  44. $ GS_INIT = "GS_INIT.PS"
  45. $ GS_LIB_DEFAULT = F$ENVIRONMENT("DEFAULT")
  46. $ IF P1 .NES. "" .AND. P1 .NES. "DEBUG" THEN GS_LIB_DEFAULT = P1
  47. $ IF P2 .NES. "" .AND. P2 .NES. "DEBUG" THEN GS_LIB_DEFAULT = P2
  48. $ !
  49. $ IF P1 .NES. "DEBUG" .AND. P2 .NES. "DEBUG" THEN GOTO NODEBUG
  50. $ CDEF = "/DEFINE=(""DEBUG"")/NOOPTIMIZE/DEBUG"
  51. $ LDEF = "/DEBUG"
  52. $ !
  53. $ NODEBUG:
  54. $ !
  55. $ ! Is GNU C about and defined?
  56. $ !
  57. $ IF F$TRNLNM("GNU_CC") .NES. "" THEN GOTO GNU_CC_OKAY
  58. $ WRITE SYS$OUTPUT "GNU_CC logical is undefined.  You must execute the command"
  59. $ WRITE SYS$OUTPUT "file GCC_INSTALL.COM in the GNU CC directory before using"
  60. $ WRITE SYS$OUTPUT "this command file."
  61. $ EXIT
  62. $ !
  63. $ !
  64. $ GNU_CC_OKAY:
  65. $ SET COMMAND GNU_CC:[000000]GCC.CLD
  66. $ !
  67. $ !
  68. $ ! Compile genarch.c and then run it to create the arch.h header file
  69. $ !
  70. $ GCC/NOLIST/OBJECT=GENARCH.OBJ GENARCH.C
  71. $ LINK/NOMAP/EXE=GENARCH.EXE GENARCH,GNU_CC:[000000]GCCLIB/LIB,SYS$INPUT/OPT
  72. SYS$SHARE:VAXCRTL/SHARE
  73. $ GENARCH = "$" + F$ENVIRONMENT("DEFAULT") + "GENARCH.EXE"
  74. $ GENARCH ARCH.H
  75. $ DELETE GENARCH.EXE.*,GENARCH.OBJ.*
  76. $ PURGE ARCH.H
  77. $ !
  78. $ !
  79. $ ! Create a minimal gconfig.h.  To add devices, look in DEVS.MAK to find
  80. $ ! the files that comprise the driver, and add them to the compilation
  81. $ ! and linking lists below.  Then add a line below the CREATE of the form
  82. $ !    device_(gs_the-device-name_device)
  83. $ ! e.g.
  84. $ !    device_(gs_bj10e_device)
  85. $ ! To incorporate compiled fonts, add the line
  86. $ !    oper_(ccfonts_op_defs)
  87. $ ! and then, for each font name XYZ, a line of the form
  88. $ !    font_("0.font_XYZ",gsf_XYZ,zf_XYZ)
  89. $ ! Also add the name ICCFONT and the names of the compiled fonts
  90. $ ! to the compilation and linking lists.
  91. $ !
  92. $ !
  93. $ CREATE GCONFIG.H
  94. device_(gs_x11_device)
  95. $ !
  96. $ ! Create an empty object library
  97. $ !
  98. $ LIBRARY/CREATE GS.OLB
  99. $ !
  100. $ !
  101. $ ! Create a list of modules to compile and store in the object library
  102. $ !
  103. $ CREATE MODULES.LIS
  104. GDEVMEM1
  105. GDEVMEM2
  106. GDEVMEM3
  107. GP_VMS
  108. GSCHAR
  109. GSCHAR0
  110. GSCIE
  111. GSCOLOR
  112. GSCOLOR2
  113. GSCOORD
  114. GSDEVICE
  115. GSDPS1
  116. GSFILE
  117. GSFONT
  118. GSIMAGE
  119. GSIMAGE2
  120. GSIMPATH
  121. GSLINE
  122. GSMATRIX
  123. GSMISC
  124. GSPAINT
  125. GSPATH
  126. GSPATH2
  127. GSSTATE
  128. GSTDEV
  129. GSTYPE1
  130. GSUTIL
  131. GXCACHE
  132. GXCLIST
  133. GXCOLOR
  134. GXCPATH
  135. GXDITHER
  136. GXDRAW
  137. GXFILL
  138. GXHINT1
  139. GXHT
  140. GXPATH
  141. GXPATH2
  142. GXPCOPY
  143. GXSTROKE
  144. IALLOC
  145. IBNUM
  146. IBSCAN
  147. ICCFONT
  148. IDEBUG
  149. IDICT
  150. IDPARAM
  151. IINIT
  152. INAME
  153. INTERP
  154. ISAVE
  155. ISCAN
  156. IUTIL
  157. SCFD
  158. SCFE
  159. SFILTER
  160. SFILTER2
  161. SLZWD
  162. SLZWE
  163. STREAM
  164. ZARITH
  165. ZARRAY
  166. ZBSEQ
  167. ZCHAR
  168. ZCIE
  169. ZCOLOR
  170. ZCOLOR2
  171. ZCONTROL
  172. ZDEVICE
  173. ZDICT
  174. ZDPS1
  175. ZFILE
  176. ZFILEIO
  177. ZFILTER
  178. ZFILTER2
  179. ZFONT
  180. ZFONT0
  181. ZFONT1
  182. ZFONT2
  183. ZGENERIC
  184. ZGSTATE
  185. ZHT
  186. ZIMAGE2
  187. ZMATH
  188. ZMATRIX
  189. ZMISC
  190. ZPACKED
  191. ZPAINT
  192. ZPATH
  193. ZPATH2
  194. ZPROPS
  195. ZRELBIT
  196. ZSTACK
  197. ZSTRING
  198. ZTYPE
  199. ZUPATH
  200. ZVMEM
  201. $ !
  202. $ !
  203. $ ! NOW COMPILE AWAY!
  204. $ !
  205. $ OPEN/READ MODULE_LIST MODULES.LIS
  206. $ !
  207. $ COMPILE_LOOP:
  208. $ READ/END=END_COMPILE MODULE_LIST MODULE
  209. $ GCC'CDEF/NOLIST/OBJECT='MODULE'.OBJ 'MODULE'.C
  210. $ LIBRARY/INSERT GS.OLB 'MODULE'.OBJ
  211. $ DELETE 'MODULE'.OBJ.*
  212. $ GOTO COMPILE_LOOP
  213. $ !
  214. $ END_COMPILE:
  215. $ CLOSE MODULE_LIST
  216. $ DELETE MODULES.LIS.*
  217. $ !
  218. $ !
  219. $ ! Is the DECwindows environment about?  Must be installed in order to
  220. $ ! build the executable program gs.exe.
  221. $ !
  222. $ IF F$SEARCH("SYS$SHARE:DECW$XLIBSHR.EXE") .NES. "" THEN GOTO CHECK2
  223. $ WRITE SYS$OUTPUT "DECwindows user environment not installed;"
  224. $ WRITE SYS$OUTPUT "unable to build executable programs."
  225. $ GOTO DONE
  226. $ !
  227. $ CHECK2:
  228. $ IF F$TRNLNM("DECW$INCLUDE") .NES. "" THEN GOTO BUILD_EXES
  229. $ WRITE SYS$OUTPUT "You must invoke @DECW$STARTUP before using this"
  230. $ WRITE SYS$OUTPUT "command procedure to build the executable programs."
  231. $ GOTO DONE
  232. $ !
  233. $ !
  234. $ BUILD_EXES:
  235. $ !
  236. $ LIBDEF = """GS_LIB_DEFAULT=""""" + ''GS_LIB_DEFAULT' + """"""""
  237. $ INIDEF = """GS_INIT=""""" + ''GS_INIT' + """"""""
  238. $ GCC'CDEF/NOLIST/DEFINE=('LIBDEF','INIDEF')/OBJECT=GCONFIG.OBJ GCONFIG.C
  239. $ GCC'CDEF/NOLIST/INCLUDE_DIRECTORY='F$TRNLNM("SYS$COMMON") -
  240.     /OBJECT=GDEVXINI.OBJ GDEVXINI.C
  241. $ GCC'CDEF/NOLIST/INCLUDE_DIRECTORY='F$TRNLNM("SYS$COMMON")/OBJECT=GDEVX.OBJ -
  242.     GDEVX.C
  243. $ GCC'CDEF/NOLIST/OBJECT=GSMAIN.OBJ GSMAIN.C
  244. $ !
  245. $ GCC'CDEF/NOLIST/OBJECT=GS.OBJ GS.C
  246. $ LINK'LDEF/NOMAP/EXE=GS.EXE GS,GSMAIN,GDEVX,GDEVXINI,GCONFIG,-
  247.   GS/LIB/INCLUDE=(GDEVMEM1,GDEVMEM2,GDEVMEM3,GXCLIST,-
  248.   ZARITH,ZARRAY,ZBSEQ,ZCHAR,ZCOLOR,ZCOLOR2,ZCONTROL,ZDEVICE,ZDPS1,-
  249.   ZDICT,ZFILE,ZFILEIO,ZFILTER,ZFILTER2,ZFONT,ZFONT0,ZFONT1,ZFONT2,-
  250.   ZGENERIC,ZGSTATE,ZHT,ZIMAGE2,ZMATH,ZMATRIX,ZMISC,-
  251.   ZPACKED,ZPAINT,ZPATH,ZPATH2,-
  252.   ZPROPS,ZRELBIT,ZSTACK,ZSTRING,ZTYPE,ZUPATH,ZVMEM),SYS$INPUT/OPT
  253. SYS$SHARE:DECW$DWTLIBSHR/SHARE,SYS$SHARE:DECW$XLIBSHR.EXE/SHARE
  254. $ !
  255. $ DELETE GDEVX.OBJ.*,GDEVXINI.OBJ.*,GSMAIN.OBJ.*,GS.OBJ.*,-
  256.          GCONFIG.OBJ.*
  257. $ !
  258. $ DONE:
  259. $ ! ALL DONE
  260.